package windows;

import java.awt.Checkbox;

import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.SpringLayout;

public class ReportGeneratorFrame {
	private JFrame frame;
	private Checkbox checkRaiffeisen = new Checkbox("Raiffeisen Bank");
	private Checkbox checkTransilvania = new Checkbox("Banca Transilvania");
	private JButton reportGenerator;

	public JButton getReportGenerator() {
		return reportGenerator;
	}

	public void setFrame() {
		SpringLayout layout = new SpringLayout();
		JPanel panel = new JPanel();
		frame = new JFrame("Report Generator");
		
		reportGenerator = new JButton("Genereaza");
		reportGenerator.setActionCommand("reportGenerator"); 
		
		panel.setLayout(layout);

		panel.add(checkRaiffeisen);
		panel.add(checkTransilvania);
		panel.add(reportGenerator);

		layout.putConstraint(SpringLayout.WEST, checkRaiffeisen, 20,
				SpringLayout.WEST, panel);
		layout.putConstraint(SpringLayout.NORTH, checkRaiffeisen, 20,
				SpringLayout.NORTH, panel);

		layout.putConstraint(SpringLayout.WEST, checkTransilvania, 20,
				SpringLayout.WEST, panel);
		layout.putConstraint(SpringLayout.NORTH, checkTransilvania, 20,
				SpringLayout.SOUTH, checkRaiffeisen);

		layout.putConstraint(SpringLayout.WEST, reportGenerator, 20,
				SpringLayout.WEST, checkTransilvania);
		layout.putConstraint(SpringLayout.NORTH, reportGenerator, 20,
				SpringLayout.SOUTH, checkTransilvania);

		frame.getContentPane().add(panel);
		frame.setSize(200, 200);

	}

	public void showFrame() {
		frame.setVisible(true);
	}

	public JFrame getFrame() {
		return frame;
	}

	public Checkbox getCheckRaiffeisen() {
		return checkRaiffeisen;
	}

	public Checkbox getCheckTransilvania() {
		return checkTransilvania;
	}
}